<?php

class musicforrobots_scraper extends BlogScraper
{
    function __construct()
    {
        parent::__construct('musicforrobots');
    }

    function getPostLinks()
    {
        $posts = $this->xpath->query("//div[@class='posted']/a"); 
        
        $internal_links = array();
        foreach ($posts as $post)
        {
            if (strpos('music.for-robots.com', $post->getAttribute('href'))) $internal_links[] = $post;
        }
        
        return $posts;
        
    }

}

class musicforrobots_post_scraper extends PostScraper
{
    function getDate()
    {
        $date_node = $this->xpath->query("//html//body//div[@class='posted']")->item(0)->nodeValue;
        $date_parts = explode('|', $date_node);
        $date = $date_parts[0];
        echo $date;
        return date('Y-m-d H:i:s', strtotime($date));

    }
   
    
}

?>